
#include "stdafx.h"
#include "resource.h"
#include "LoginDlg.h"

LRESULT CLoginDlg::OnInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/)
{
	CenterWindow(GetParent());

	SetDlgItemText(IDC_EDIT_USERNAME, _T("hapike2@gmail.com"));
	SetDlgItemText(IDC_EDIT_PASSWORD, _T(""));

	return TRUE;
}

LRESULT CLoginDlg::OnOK(WORD /*wNotifyCode*/, WORD /*wID*/, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
	GetDlgItemText(IDC_EDIT_USERNAME, m_strUserName);
	GetDlgItemText(IDC_EDIT_PASSWORD, m_strPassword);

	EndDialog(IDOK);
	return 0;
}

LRESULT CLoginDlg::OnCancel(WORD /*wNotifyCode*/, WORD /*wID*/, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
{
	EndDialog(IDCANCEL);
	return 0;
}
